﻿function First() {
    try {
        document.getElementById("ctl00_ContentPlaceHolder3_hf_Count").value = "0";
    }

    catch (Ex) {
        alert(Ex.message);
    }
}

function Previous() {
    try {
        var iValue = document.getElementById("ctl00_ContentPlaceHolder3_hf_Count").value;
        if (parseInt(iValue) > 0)
            iValue = parseInt(iValue) - 1;
        else
            iValue = 0;
        document.getElementById("ctl00_ContentPlaceHolder3_hf_Count").value = iValue;
    }

    catch (Ex) {
        alert(Ex.message);
    }
}

function Next() {
    try {
        var iValue = document.getElementById("ctl00_ContentPlaceHolder3_hf_Count").value;
        if (parseInt(iValue) >= parseInt(document.getElementById("ctl00_ContentPlaceHolder3_hf_Total").value)) return false;
        iValue = parseInt(iValue) + 1;
        document.getElementById("ctl00_ContentPlaceHolder3_hf_Count").value = iValue;
    }

    catch (Ex) {
        alert(Ex.message);
    }
}

function Last() {
    try {
        document.getElementById("ctl00_ContentPlaceHolder3_hf_Count").value = document.getElementById("ctl00_ContentPlaceHolder3_hf_Total").value;
    }

    catch (Ex) {
        alert(Ex.message);
    }
}